<?php
include "includes/comunes.php";
if (!function_exists('json_encode')) {
	require_once 'json/jsonwrapper_inner.php';
}



$array = array();
if ($_GET['_name'] == 'vehiculo')
{

	 if ( $_GET['_value'] == 0 )//usa
	 {
		$array[] = array('0' => 'Sin valores');
		
	  } else
	  {
              $sqlplanes="select * from veh_responsables_vehiculo where ResVehiculo=".$_GET['_value'];
              $respla=cons_sql_up($sqlplanes);
              while ($reg=  mysql_fetch_array($respla)){
			  $resNombre=obtener_responsable_vehiculo($reg['ResChofer']);
              $array[] = array($reg['ResChofer'] => utf8_encode($resNombre));
             
              }

	  }
}  else
{
	$array[] = array('1' => 'Data 1');
	$array[] = array('2' => 'Data 2');	
	$array[] = array('3' => 'Data 3');	
}
echo json_encode( $array );
?>
